package xyz.csmcool.imoss.utils;

import java.util.UUID;

/**
 * @author 什锦
 * @Package xyz.csmcool.imoss.utils
 * @since 2022/8/5 15:07
 */

public class NameUtil {

    /**
     * 根据UUID生成唯一文件名
     * @param originalName
     * @return
     */
    public static String generateUniqueName(String originalName) {
        return UUID.randomUUID() + originalName.substring(originalName.lastIndexOf("."));
    }
}
